#!/bin/bash
count=`ps -ef|grep midservice|grep -v grep|wc -l`
if [ $count -gt 0 ];then
	onsale_pid=`ps -ef | grep midservice |grep -v grep| awk '{print $2}'`
	kill $onsale_pid
	echo "midservice shutdowned!"
else
    echo "midservice dosen't exists!"
fi